<?php


namespace app\shop\controller;


use app\BaseController;
use app\dao\user\ShopUserDao;
use app\model\Shop;
use app\Request;
use app\shop\service\AuthService;
use think\App;

class AuthController extends BaseController
{
    public function login(Request $request)
    {
        $authService = new AuthService();
        $js_code = $request->param('js_code', '');

        $token = $authService->login(SUBDOMAIN, $js_code);

        return $this->returnJson(['token' => $token]);
        
    }
}